#ifndef PCB_H
#define PCB_H
#include<QString>
#include<QPushButton>
class PCB
{
public:
    PCB();
    PCB(QString processName,QString PID,QString inPut,QString outPut,int needTime,int priorityWeight,int mode,int needMemorySize,QString frontID);
    PCB(QString processName,QString PID,QString inPut,QString outPut,int needTime,int priorityWeight,int mode,int needMemorySize,QString frontID,QString backID);
    PCB(QString processName,QString PID,QString inPut,QString outPut,int needTime,int priorityWeight,int mode,int needMemorySize);
    //PCB(PCB &p);

    void copyPCB(PCB &p1,PCB &p2);
    void randomPCB(PCB &p1);
    void setneedMemorySize();

    QString processName;
    QString PID;

    QString inPut;
    QString outPut;


    int needTime;
    int priorityWeight;
    int mode;
    int olderTime = 0;
    QString frontID;
    QString backID;

    PCB* front;
    /*
       1 is ready
       2 is waiting
       3 is reserve
       0 is completed
       -1 is hang-up
    */

    int needMemorySize;
    int memoryStartAddress;

    QPushButton *button;
private:
    //    QString processName;
    //    QString PID;

    //    QString inPut;
    //    QString outPut;


    //    int needTime;
    //    int priorityWeight;
    //    int mode;

   // PCB *PCBPointer;



};

#endif // PCB_H
